<!DOCTYPE html>
<html>
	<head>
		<meta charset="UTF-8">
		<title>条件</title>
	</head>
	<body>
		<script>
			var flag = true;
			if(flag){
				document.writeln("我是true的循环条件下的结果");
			}
			else{
				document.writeln("我是非条件下的结果");
			}
			// confirm 是确认框
			var flag_confirm = window.confirm("快来电我吧");
			if(flag_confirm){
				document.writeln("confirm框你点的是ok把");
			}
			else{
				document.writeln("confirm框你点的是取消\或者没选中吧");
			}
			// prompt 是输入框
			var result = window.prompt("快来输入我");
			document.writeln("result=" + result);
		</script>
	</body>
</html>
